package org.blim.blackdawn.graph;

import java.util.ArrayList;
import java.util.List;

import org.blim.blackdawn.model.Model;

/**
 * A SceneGraph is a pure data class which holds the information needed to
 * render a scene in three dimensions.
 * 
 * <p>Specifically it holds the objects to be rendered in a tree of nested
 * ReferenceFrames, a list of the lights in the scene, the matrix which 
 * transforms the view into the correct location and the projection matrix
 * used to project the scene on to the screen.</p>
 * 
 * @author lee@longlost.info
 */
public class SceneGraph {

	public float[] mView = new float[16];
	public float[] mProjection = new float[16];
	
	public final ReferenceFrame mWorld;
	public List<ReferenceFrame> mLights;
	
	public SceneGraph() {
		mWorld = new ReferenceFrame();
		
		mLights = new ArrayList<ReferenceFrame>();
	}
	
	public SceneGraph(Model origin) {
		mWorld = new ReferenceFrame(null, null, origin, null);
		
		mLights = new ArrayList<ReferenceFrame>();
	}
	
}
